home *** CD-ROM | disk | FTP | other *** search
/ The Atari Compendium / The Atari Compendium (Toad Computers) (1994).iso / files / prgtools / gnustuff / tos / othergnu / ispell.zoo / ispell.doc < prev    next >
Encoding:
Text File  |  1990-04-19  |  15.2 KB  |  397 lines

  1.  
  2.  
  3.  
  4. ISPELL(local)     UNKNOWN SECTION OF THE MANUAL     ISPELL(local)
  5.  
  6.  
  7.  
  8. NAME
  9.      ispell - Correct spelling for a file
  10.      munchlist - Combine suffixes in a spelling list
  11.      isexpand - Expand suffixes in a spelling list
  12.  
  13. SYNOPSIS
  14.      ispell [ -t | -x | -S | -d file | -p file | -w chars ]  file
  15.      .....
  16.      ispell [ -t | -d file | -p file | -w chars ] -l
  17.      ispell [ -t | -d file | -p file ] { -a | -A }
  18.      ispell [ -w chars ] -c
  19.      ispell -v
  20.      munchlist [ -d file | -e | -w chars ] [ files ]
  21.      isexpand [ files ]
  22.  
  23. DESCRIPTION
  24.      Ispell is fashioned after the spell program from ITS (called
  25.      ispell on Twenex systems.)  The most common usage is "ispell
  26.      filename".  In this case,  ispell  will  display  each  word
  27.      which  does  not  appear in the dictionary, and allow you to
  28.      change it.  If there are "near  misses"  in  the  dictionary
  29.      (words  which  differ  by only a single letter, a missing or
  30.      extra letter, or a pair of transposed  letters),  then  they
  31.      are  also displayed.  If you think the word is correct as it
  32.      stands, you can type either "Space" to accept  it  this  one
  33.      time,  or  "I"  to accept it and put it in your private dic-
  34.      tionary.  If one of the near misses is the  word  you  want,
  35.      type  the  corresponding number.  (If there are more than 10
  36.      choices, you may have to type a carriage return to  complete
  37.      a  single-digit  number).  Finally, if none of these choices
  38.      is right, you can type "R" and you will be  prompted  for  a
  39.      replacement  word.   If you want to see a list of words that
  40.      might be close using wildcard characters, type "L" to lookup
  41.      a word in the system dictionary.
  42.  
  43.      When a misspelled word is found, it is printed at the top of
  44.      the  screen.  Any near misses will be printed on the follow-
  45.      ing lines, and finally, two lines containing  the  word  are
  46.      printed  at  the bottom of the screen.  If your terminal can
  47.      type in reverse video, the word itself is highlighted.
  48.  
  49.      The -v option causes ispell to  print  its  current  version
  50.      identification on the standard output and exit.
  51.  
  52.      The -l or "list" option to ispell is used to produce a  list
  53.      of misspelled words from the standard input.
  54.  
  55.      The -a option is intended to be  used  from  other  programs
  56.      through  a  pipe.  In this mode, ispell expects the standard
  57.      input to consist of lines  containing  single  words.   Each
  58.      word  is  read, and a single line is written to the standard
  59.      output.  If the word was found in the  main  dictionary,  or
  60.  
  61.  
  62.  
  63. Sun Release 3.5         Last change: MIT                        1
  64.  
  65.  
  66.  
  67.  
  68.  
  69.  
  70. ISPELL(local)     UNKNOWN SECTION OF THE MANUAL     ISPELL(local)
  71.  
  72.  
  73.  
  74.      your personal dictionary, then the line contains only a '*'.
  75.      If the word was found through suffix removal, then the  line
  76.      contains  a '+', a space, and the root word.  If the word is
  77.      not in the dictionary, but there are near misses,  then  the
  78.      line contains an '&', a space, and a list of the near misses
  79.      separated by spaces.  Also, each near  miss  is  capitalized
  80.      the  same as the input word if unless such capitalization is
  81.      illegal; in the latter case each near  miss  is  capitalized
  82.      correctly according to the dictionary.  Finally, if the word
  83.      neither appears in the dictionary, and  there  are  no  near
  84.      misses,  then  the  line  contains only a '#'.  This mode is
  85.      also suitable for interactive use when you  want  to  figure
  86.      out  the  spelling  of a single word.  (These characters are
  87.      the same as the codes that the real spell program uses.)
  88.  
  89.      The -A option works just like -a,  except  that  if  a  line
  90.      begins  with  the  string  "&Include_File&", the rest of the
  91.      line is taken as the name of a  file  to  read  for  further
  92.      words.   Input returns to the original file when the include
  93.      file is exhausted.  Inclusion may be nested up to five deep.
  94.      The  key string may be changed with the environment variable
  95.      INCLUDE_STRING (the ampersands, if any, must be included).
  96.  
  97.      When in the -a mode, ispell will also accept lines of single
  98.      words  prefixed with either a '*' or a '@'.  A line starting
  99.      with '*' tells ispell to insert the  word  into  the  user's
  100.      dictionary (similar to the I command).  A line starting with
  101.      '@' causes ispell to accept this word in the future (similar
  102.      to the A command).
  103.  
  104.      The -x option causes ispell to remove the .bak file that  it
  105.      normally  leaves.   The .bak file contains the pre-corrected
  106.      text.  If there are file opening / writing errors, the  .bak
  107.      file  may  be  left  for  recovery purposes even with the -x
  108.      option.
  109.  
  110.      The -S option suppresses ispell's normal behavior of sorting
  111.      the  list  of  possible  replacement words.  Some people may
  112.      prefer this, since it somewhat enhances the probability that
  113.      the correct word will be low-numbered.
  114.  
  115.      The -t option selects TeX/LaTeX input mode.  TeX/LaTeX  mode
  116.      is  also  automatically  selected  if  an input file has the
  117.      extension ".tex".  In this mode, whenever a backslash  ("\")
  118.      is  found,  ispell  will skip to the next whitespace.  Thus,
  119.      for example, given
  120.           \chapter {This is a Ckapter} \cite{SCH86}
  121.      will find "Ckapter" but will  not  look  for  SCH.   The  -t
  122.      option does not recognize the TeX comment character "%".
  123.  
  124.      The -d option is used to specify an  alternate  hashed  dic-
  125.      tionary  file, other than the default.  If the filename does
  126.  
  127.  
  128.  
  129. Sun Release 3.5         Last change: MIT                        2
  130.  
  131.  
  132.  
  133.  
  134.  
  135.  
  136. ISPELL(local)     UNKNOWN SECTION OF THE MANUAL     ISPELL(local)
  137.  
  138.  
  139.  
  140.      not begin with a "/", the library directory for the  default
  141.      dictionary  file  is prefixed.  This is useful to allow dic-
  142.      tionaries which prefer alternate  British  spellings  ("cen-
  143.      tre",  "tyre",  etc), or add lists of special-purpose jargon
  144.      and acronyms for subclasses of documents.   There  are  some
  145.      shortcomings  in attempting to provide foreign-language dic-
  146.      tionaries, but something like "-d french" could be  made  to
  147.      work  somewhat.   The  -d  option  may specify /dev/null, in
  148.      which case the dictionary is limited to  the  personal  one.
  149.      This may be useful for certain private dictionaries.
  150.  
  151.      The -p option is used to specify an alternate personal  dic-
  152.      tionary  file.   If  the  file name does not begin with "/",
  153.      $HOME is prefixed.  Also, the shell variable WORDLIST may be
  154.      set,  which  renames  the  personal  dictionary  in the same
  155.      manner.  The command line overrides  WORDLIST  setting.   If
  156.      neither is present "~/.ispell_words" is used.
  157.  
  158.      The -w option may be used to specify characters  other  than
  159.      alphabetics  which  may also appear in words.  For instance,
  160.      -w "&" will allow "AT&T" to be picked up.   Underscores  are
  161.      useful  in many technical documents.  There is an admittedly
  162.      crude provision in this option for 8-bit international char-
  163.      acters.   Non-printing  characters  may  be specified in the
  164.      usual way by inserting a backslash  followed  by  the  octal
  165.      character  code;  e.g.,  "\014"  for  a form feed.  Alterna-
  166.      tively, if "n" appears in the character string, the (up  to)
  167.      three  characters  following are a DECIMAL code 0 - 255, for
  168.      the character.  For example, to include bells and form feeds
  169.      in  your  words (an admittedly silly thing to do, but aren't
  170.      most pedagogical examples):
  171.  
  172.      n007n012
  173.  
  174.      Numeric digits other than the three following "n" are simply
  175.      numeric  characters.  Use of "n" does not conflict with any-
  176.      thing because actual alphabetics have no meaning - alphabet-
  177.      ics  are  already  accepted.   Ispell will typically be used
  178.      with input from a file, meaning that preserving  parity  for
  179.      possible 8 bit characters from the input text is OK.  If you
  180.      specify the -l option, and actually type text from the  ter-
  181.      minal,  this  may  create  problems  if  your  stty settings
  182.      preserve parity.
  183.  
  184.      The -c option is primarily intended for use by the munchlist
  185.      shell  script.   In  this mode, a list of words is read from
  186.      the standard input.  For each word, a list of possible  root
  187.      words  and  suffixes will be written to the standard output.
  188.      Some of the root words will be illegal and must be  filtered
  189.      from  the  output  by other means; the munchlist script does
  190.      this.  As an example, the command "echo BOTHER | ispell  -c"
  191.      produces:
  192.  
  193.  
  194.  
  195. Sun Release 3.5         Last change: MIT                        3
  196.  
  197.  
  198.  
  199.  
  200.  
  201.  
  202. ISPELL(local)     UNKNOWN SECTION OF THE MANUAL     ISPELL(local)
  203.  
  204.  
  205.  
  206.           BOTH
  207.           BOTHE/R
  208.           BOTH/R
  209.  
  210.      Unless it has been installed without  the  feature  by  your
  211.      system  administrator,  ispell is aware of the correct capi-
  212.      talizations of words in the dictionary and in your  personal
  213.      dictionary.  As well as recognizing words that must be capi-
  214.      talized (e.g., George) and words that must  be  all-capitals
  215.      (e.g.,  NASA), it can also handle words with "unusual" capi-
  216.      talization (e.g., "ITCorp" or "TeX").  If a word is capital-
  217.      ized incorrectly, the list of possibilities will include all
  218.      acceptable capitalizations.  (More than  one  capitalization
  219.      may  be  acceptable;  for  example, my dictionary lists both
  220.      "ITCorp" and "ITcorp".)  Normally,  this  feature  will  not
  221.      cause  you surprises, but there is one circumstance you need
  222.      to be aware of.  If you add a word to your  dictionary  that
  223.      is  at  the beginning of a sentence (e.g., the first word of
  224.      this paragraph if "unless" were not in the  dictionary),  it
  225.      will  be  marked as "capitalization required".  A subsequent
  226.      usage of this word without capitalization (e.g., the  quoted
  227.      word  in the previous sentence), ispell will object and sug-
  228.      gest the capitalized version.  You  must  then  compare  the
  229.      actual  spellings  by  eye, and then type "I" to add the un-
  230.      capitalized variant to your personal dictionary.
  231.  
  232.      The rules for capitalization are as follows:
  233.  
  234.      (1)  Any word may appear in all capitals, as in headings.
  235.  
  236.      (2)  Any word that is in  the  dictionary  in  all-lowercase
  237.           form  may appear either in lowercase or capitalized (as
  238.           at the beginning of a sentence).
  239.  
  240.      (3)  Any word that has "funny" capitalization (i.e., it con-
  241.           tains  both  cases  and there is an uppercase character
  242.           besides the first) must appear exactly as in  the  dic-
  243.           tionary,  except as permitted by rule (1).  If the word
  244.           is acceptable in all-lowercase, it must appear thus  in
  245.           a dictionary entry.
  246.  
  247.      The munchlist shell script is used to  reduce  the  size  of
  248.      dictionary  files,  primarily personal dictionary files.  It
  249.      is also  capable  of  combining  dictionaries  from  various
  250.      sources.   The  given  files  are read (standard input if no
  251.      arguments are given), reduced to a minimal set of roots  and
  252.      suffixes that will match the same list of words, and written
  253.      to standard output.
  254.  
  255.      Normally, words that  are  in  the  default  dictionary  are
  256.      removed  by  munchlist during processing.  If the list is to
  257.      be used with a different dictionary, the -d  option  can  be
  258.  
  259.  
  260.  
  261. Sun Release 3.5         Last change: MIT                        4
  262.  
  263.  
  264.  
  265.  
  266.  
  267.  
  268. ISPELL(local)     UNKNOWN SECTION OF THE MANUAL     ISPELL(local)
  269.  
  270.  
  271.  
  272.      used  to  specify an alternate (hashed) dictionary file con-
  273.      taining words to be removed from the output list.  If a dic-
  274.      tionary  file  of  /dev/null  is specified, no words will be
  275.      removed from the output; this is useful  when  munching  the
  276.      primary dictionary file.
  277.  
  278.      The -w option is passed on to ispell.  The -e  ("efficient")
  279.      option causes the script to use a slower algorithm that uses
  280.      somewhat less space in TMPDIR (normally /usr/tmp).
  281.  
  282.      The isexpand shell script is used to expand the various suf-
  283.      fix  flags  in an ispell word list.  This script can be used
  284.      when looking words up in the dictionary, or to verify that a
  285.      particular   suffix  flag  actually  produces  the  expected
  286.      result.
  287.  
  288.      It is possible to install ispell in such a way  as  to  only
  289.      support ASCII range text if desired.
  290.  
  291. ENVIRONMENT
  292.      WORDLIST       Personal dictionary file name
  293.      INCLUDE_STRING      Code for file  inclusion  under  the  -A
  294.      option
  295.      TMPDIR         Directory used for some of  munchlist's  tem-
  296.      porary files
  297.  
  298. FILES
  299.      $HOME/.ispell_words      user's private dictionary
  300.      /usr/dict/words          list of words for the Lookup  func-
  301.      tion
  302.      /tools/sources/ispell           directory for the  following
  303.      files:
  304.      ispell.hash         hashed dictionary for ispell
  305.      isexp[1-4].sed      sed scripts for expanding suffixes
  306.      icombine       program for combining suffix flags
  307.      munchlist      munchlist program
  308.      isexpand       isexpand program
  309.      makedict*      making your own dictionaries
  310.      fixdict        fix capitalization in dictionary
  311.      ispell.4.hlp        description of dictionary entries
  312.      ispell.el      sample GNU Emacs interface to ispell
  313.  
  314. SEE ALSO
  315.      spell(1), egrep(1), look(1), ispell(4)
  316.  
  317. BUGS
  318.      It takes about five seconds for ispell to read in  the  hash
  319.      table.
  320.  
  321.      The hash table is stored as a quarter-megabyte  (or  larger)
  322.      array, so a PDP-11 version does not seem likely.
  323.  
  324.  
  325.  
  326.  
  327. Sun Release 3.5         Last change: MIT                        5
  328.  
  329.  
  330.  
  331.  
  332.  
  333.  
  334. ISPELL(local)     UNKNOWN SECTION OF THE MANUAL     ISPELL(local)
  335.  
  336.  
  337.  
  338.      Ispell should understand more troff syntax,  and  deal  more
  339.      intelligently with contractions.
  340.  
  341.      While alternate dictionaries for foreign languages could  be
  342.      defined, and the international characters included in words,
  343.      rules concerning word endings  /  pluralization  accommodate
  344.      English only.
  345.  
  346.      When the -x flag is specified, ispell will unlink any exist-
  347.      ing .bak file.
  348.  
  349.      Munchlist requires  tremendous  amounts  of  temporary  file
  350.      space  for  large  dictionaries.  It does respect the TMPDIR
  351.      environment variable, so this space can be redirected.  How-
  352.      ever,  a lot of the temporary space it needs is for sorting,
  353.      so TMPDIR  is  only  a  partial  help  on  systems  with  an
  354.      uncooperative  sort(1).   As  a  benchmark,  the  15000-word
  355.      dict.191 takes about 1200 blocks  in  TMPDIR,  and  2000  in
  356.      sort's   temporary   directories.   Munching  dict.191  with
  357.      /usr/dict/words  (28000  words  output)  took  another  1500
  358.      blocks or so, and ran for the better part of an hour.
  359.  
  360. AUTHOR
  361.      Pace Willisson (pace@mit-vax)
  362.      Collected, revised, and enhanced  for  the  Usenet  by  Walt
  363.      Buehring.
  364.      Further enhanced and debugged by Isaac Balbin, Stewart  Cla-
  365.      men,  Mark  Davies, Steve Dum, Gary Johnson, Don Kark, Steve
  366.      Kelem, Jim Knutson, Geoff Kuenning, Evan Marcus, Dave Mason,
  367.      Rob  McMahon,  Bob  McQueer,  David Neves, Joe Orost, Israel
  368.      Pinkas, Gary Puckering, Bill Randle, Marc Ries,  Rich  Salz,
  369.      Greg  Schaffer,  Joel  Shprentz,  George  Sipe, Perry Smith,
  370.      Stefan Taxhet, Andrew Vignaux, Johan Widen, James Woods, and
  371.      Ken Yap.
  372.  
  373.  
  374.  
  375.  
  376.  
  377.  
  378.  
  379.  
  380.  
  381.  
  382.  
  383.  
  384.  
  385.  
  386.  
  387.  
  388.  
  389.  
  390.  
  391.  
  392.  
  393. Sun Release 3.5         Last change: MIT                        6
  394.  
  395.  
  396.  
  397.